package com.example.util;

import android.content.Context;
import android.util.Log;
import android.view.Gravity;
import android.widget.Toast;

public class Util {
	private Context context;
	public Util(Context c){
		this.context = c;
	}
	//第一个调试用的alert方法
	@SuppressWarnings("null")
	public void alert(CharSequence text){
		Log.d("LOG","开始调用alert："+this.context.getPackageName());
		Toast toast = new Toast(this.context);
		toast = Toast.makeText(this.context, text, 1000);
		toast.setGravity(Gravity.CENTER, 0, 0);
		toast.show();
	}
}
